package android_design_mode.chapter16_visitor;

import java.util.LinkedList;
import java.util.List;

public class BusinessReport {
    List<Staff> mStaffs = new LinkedList<>();


    public BusinessReport() {
        mStaffs.add(new Manager("Manager-AAA"));
        mStaffs.add(new Engineer("Engineer-001"));
        mStaffs.add(new Engineer("Engineer-001"));
        mStaffs.add(new Engineer("Engineer-001"));
        mStaffs.add(new Engineer("Engineer-001"));
    }


    public void showReport(Visitor visitor) {
        for (Staff staff : mStaffs) {
            staff.accept(visitor);
        }
    }
}
